<?php
class Conexion{

private $Servidor = 'localhost';
private $Usuario ='root';
private $Clave='letty';
private $Basedato='magsi_db';



private function Conectar(){
$con = mysqli_connect($this->Servidor,$this->Usuario,$this->Clave,$this->Basedato) or die('error');
return $con;
}

public function insertarReproduccion($RE){

$RE = implode("|",$_POST["re"]);
 $sql = "INSERT INTO ma_ag_tiporepro(MA_In_TipoRepro)
 	 VALUES ('$RE')";

     $con =$this->Conectar();
      mysqli_query($con,$sql) or die('no insertado'.mysqli_error($con));

      if($con){

header('location:index.php');


      }
}


	}





?>